package com.liy.cloud.common.base.entity;

import javax.validation.constraints.NotNull;
import javax.validation.constraints.Size;

import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
import org.apache.ibatis.annotations.Insert;
import org.hibernate.validator.constraints.NotBlank;

import com.das.framework.common.vo.BaseVO;

import java.util.List;

/**
 * @Author: zhangw
 * @Date: 2018/6/22  9:22
 * @Description: 设备信息实体类
 **/
public class BaseEquInfoEntity extends BaseVO<String> {

    private static final long serialVersionUID = 1342342323L;

    /*
     * 设备编号
     **/
    @NotBlank(message = "{common.validation.notnull}", groups = {Insert.class})
    @Size(max = 10, message = "{common.validation.length}")
    private String id;

    /*
     * 线路编号
     */
    private String lineId;

    /*
     * 车站点编号
     **/
    @NotNull(groups = {Insert.class})
    @Size(max = 10, message = "{common.validation.length}")
    private String stationid;

    /*
     * 车站点编号 对应的名称
     **/
    private String stationidName;

    /*
     * 设备大类编号
     */
    private String typeCode;

    /*
     * 设备种类编号
     **/
    @Size(max = 10, message = "{common.validation.length}")
    private String devicetype;

    // (设备种类编号-对应名称)非数据库字段
    private String devicetypeName;

    // 设备种类编号集合 ( 非数据库字段)
    @JsonIgnoreProperties(ignoreUnknown = true)
    private List<String> deviceTypeList;

    /*
     * 设备名称
     **/
    @Size(max = 50, message = "{common.validation.length}")
    private String devicename;

    @Size(max = 50, message = "{common.validation.length}")
    private String deviceip;

    @Size(max = 2, message = "{common.validation.length}")
    private String flag;

    /*
     * 设备坐标
     **/
    @Size(max = 50, message = "{common.validation.length}")
    private String angle;

    @Size(max = 2, message = "{common.validation.length}")
    private String status;

    /**
    * 默认构造
    **/
    public BaseEquInfoEntity() {
        super();
    }
    /**
     * 有参构造 设备ID
     **/
    public BaseEquInfoEntity(String id) {
        this.id = id;
    }

    /**
     * 有参构造 车站Id  设备种类
     **/
    public BaseEquInfoEntity(String stationid,String devicetype) {
        this.stationid = stationid;
        this.devicetype = devicetype;
    }

    /**
     * 有参构造  车站Id  设备种类集合
     **/
    public BaseEquInfoEntity(String stationid,List<String> deviceTypeList) {
        this.stationid = stationid;
        this.deviceTypeList = deviceTypeList;
    }

    @Override
    public String getId() {
        return id;
    }

    @Override
    public void setId(String id) {
        this.id = id;
    }

    public String getStationid() {
        return stationid;
    }

    public void setStationid(String stationid) {
        this.stationid = stationid;
    }

    public String getDevicetype() {
        return devicetype;
    }

    public void setDevicetype(String devicetype) {
        this.devicetype = devicetype;
    }

    public String getDevicetypeName() {
        return devicetypeName;
    }

    public void setDevicetypeName(String devicetypeName) {
        this.devicetypeName = devicetypeName;
    }

    public String getDevicename() {
        return devicename;
    }

    public void setDevicename(String devicename) {
        this.devicename = devicename;
    }

    public String getDeviceip() {
        return deviceip;
    }

    public void setDeviceip(String deviceip) {
        this.deviceip = deviceip;
    }

    public String getFlag() {
        return flag;
    }

    public void setFlag(String flag) {
        this.flag = flag;
    }

    public String getAngle() {
        return angle;
    }

    public void setAngle(String angle) {
        this.angle = angle;
    }

    public String getStatus() {
        return status;
    }

    public void setStatus(String status) {
        this.status = status;
    }

    public List<String> getDeviceTypeList() {
        return deviceTypeList;
    }

    public void setDeviceTypeList(List<String> deviceTypeList) {
        this.deviceTypeList = deviceTypeList;
    }

    public String getStationidName() {
        return stationidName;
    }

    public void setStationidName(String stationidName) {
        this.stationidName = stationidName;
    }

    public String getTypeCode() {
        return typeCode;
    }

    public void setTypeCode(String typeCode) {
        this.typeCode = typeCode;
    }

    public String getLineId() {
        return lineId;
    }

    public void setLineId(String lineId) {
        this.lineId = lineId;
    }
}
